package cn.edu.ctbu.datajpa.service.impl;


import cn.edu.ctbu.datajpa.domain.Admin;
import cn.edu.ctbu.datajpa.domain.repository.AdminRepository;
import cn.edu.ctbu.datajpa.service.AdminService;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class AdminImpIService implements AdminService {

    @Autowired
    private AdminRepository adminRepository;

    public List<Admin> findAll(){

        return adminRepository.findAll();
    }
    public List<Admin> findByNoAndPassword(String no, String password) {

        return adminRepository.findByNoAndPassword(no,password);

    }


}
